.text {
  display: inline-block;
  width: fit-content;
  height: fit-content;
  background: linear-gradient(to left, red, blue) no-repeat bottom right;
  background-size: 0 2px;
  transition: background-size 0.5s;
  cursor: pointer;

  &:hover {
    background-position: bottom left;
    background-size: 100% 2px;
  }
}
